<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <input type="button" onclick="sendGet();" value="发送Get请求">
    <input type="button" onclick="sendPost();" value="发送Post请求" /> 
    <input type="button" onclick="sendDelete();" value="发送Delete请求" /> 
    <script src="https://code.jquery.com/jquery-3.6.1.min.js"></script>
   <script>
    function sendGet () {
        $.ajax({
            type : 'get',
            url : 'method',
            success : function(body) {
                console.log(body);
            }
        });
    }
    
    function sendPost () {
        $.ajax({
            type : 'post',
            url : 'method',
            success : function(body) {
                console.log(body);
            }
        });
    }
    
    function sendDelete () {
        $.ajax({
            type : 'delete',
            url : 'method',
            success : function(body) {
                console.log(body);
            }
        });
    }
</script>
   
  
</body>
</html>